# from flask import  Blueprint,request,redirect,session,jsonify
# bp = Blueprint('write_report_bp',__name__,url_prefix='/write')
# from flask_login import login_required
# from utils.decorator import json_response
# from blueprint.write_report_bp_impl import *
# import json
# """
# 时间以‘-’作为分隔符，精确到年月日时分秒；
# 三项日报内容以/*/*/为分隔符
# """
# @bp.route('/addNewReport',methods=['POST'])
# @json_response
# # @login_required
# def addNewReport():
#     # POST请求数据获取方式：get_data()得到byte类型数据，decode成utf8编码格式的str，再用eval函数转成字典
#     data = request.get_data().decode('utf-8')
#     json_data = eval(data)
#     title = json_data['title']
#     # author = session['login_name']
#     author = 'aaa'
#     article = json_data['article']
#     if '' == author:
#         return dict(success=False, msg='为查询到登陆用户', code=900)
#     try :
#         receiver = json_data['receiver']
#         if '' == title or '' == receiver or '' == article :
#             return dict(success=False, msg='传入参数有误!', code=150)
#         try:
#             res = write_report_to_person(author, receiver, title, article)
#             return dict(success=True, data=res)
#         except Exception as err:
#             return dict(success=False, msg='日报发送异常!', code=1100)
#     except Exception as e:
#         project = json_data['project']
#         if '' == title or '' == project or '' == article :
#             return dict(success=False, msg='传入参数有误!', code=150)
#         try:
#             res = write_report_to_projectGroup(author, project, title, article)
#             return dict(success=True, data=res)
#         except Exception as err:
#             return dict(success=False, msg='日报发送异常!', code=1100)
#
#
#
